//
//  CXLoadMBProgress.m
//  Travel
//
//  Created by dllo on 15/11/29.
//  Copyright © 2015年 doll. All rights reserved.
//

#import "CXLoadMBProgress.h"
#import "MBProgressHUD.h"

@interface CXLoadMBProgress ()


@end

@implementation CXLoadMBProgress

+ (void)loadMBProgress:(UIView *)view
{
    MBProgressHUD *activity = [[MBProgressHUD alloc] initWithView:view];
    activity.tag = 1010;
    //self.activityView.backgroundColor = [UIColor grayColor];
    //self.activityView.dimBackground = YES;
    //activity.userInteractionEnabled = YES;
    activity.labelText = @"正在加载";
    activity.labelFont = [UIFont systemFontOfSize:20];
    activity.labelColor = [UIColor whiteColor];
    [view addSubview:activity];
    [activity show:YES];
}

+ (void)removeMBProgress:(UIView *)view
{
    MBProgressHUD *activity = (MBProgressHUD *)[view viewWithTag:1010];
    [activity removeFromSuperview];
}

@end
